function [x,xi,epsilon]=xpseudospectrum(A,xmin,xmax,ixmin,ixmax,n)
x=linspace(xmin,xmax,n);
xi=linspace(ixmin,ixmax,n);
m=size(A,1);
h=waitbar(0,'please wait')
for i=1:n,
    waitbar(i/n,h)
    for j=1:n
        epsilon(i,j)=-log10(abs(svds((x(i)+sqrt(-1)*xi(j))*eye(m)-A,1,0)));
    end
end
close(h)